<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>这是switch的测试</title>
</head>
<body>
<script>
  var date = 5;
  switch(date){
    case 1:
      console.log("星期一");
      break;
    case 2:
      console.log("星期二");
      break;
    case 3:
      console.log("星期三");
      break;
    case 4:
      console.log("星期四");
      break;
    case 5:
      console.log("星期五");
    case 6:
      console.log("星期六");
      break;
    case 7:
      console.log("星期日");
    default:
      console.log("未知");
  }
</script>
</body>
</html>